package com.gpms.action.twiceAuditing;

import java.io.File;
import java.util.Calendar;
import java.util.Date;
import java.util.List;
import java.util.Map;

import com.gpms.bean.FileClass;
import com.gpms.bean.Teacher;
import com.gpms.bean.Topics;
import com.gpms.bean.UploadFile;
import com.gpms.service.Topics.IShowTopicsListService;
import com.gpms.service.Topics.TopicsListFactory;
import com.gpms.service.file.FileFactory;
import com.gpms.service.file.IFileService;
import com.opensymphony.xwork2.ActionContext;

public class OneAuditingAction
{
	private List<Topics> topicss;
	private String types;
	private int oneAuditingID;
	private String information;
	private String which;
	public List<Topics> getTopicss() {
		return topicss;
	}
	public void setTopicss(List<Topics> topicss) {
		this.topicss = topicss;
	}
	public String getTypes() {
		return types;
	}
	public void setTypes(String types) {
		this.types = types;
	}
	public int getOneAuditingID() {
		return oneAuditingID;
	}
	public void setOneAuditingID(int oneAuditingID) {
		this.oneAuditingID = oneAuditingID;
	}
	public String getInformation() {
		return information;
	}
	public void setInformation(String information) {
		this.information = information;
	}
	public String execute() throws Exception
	{
		Map session = ActionContext.getContext().getSession();
		Teacher teacher = (Teacher)session.get("user");
		IShowTopicsListService operate = TopicsListFactory.createTopicsList("TeacherTopicsList");
		List<Topics> topicss = operate.showITopicsList(teacher.getTeacherNum(), "taskBook");
		setTopicss(topicss);
		if("one".equals(getWhich()))
		{
			setTypes("oneAuditing");
		}else{
			setTypes("twoAuditing");
		}
		return "success";
	}
	public String getWhich() {
		return which;
	}
	public void setWhich(String which) {
		this.which = which;
	}
}
